package bosVM2.meta.Objects;

import bosVM2.util.Map;

public class BosObject {
	
	private BosClass clss;
	private Map<String, Object> fields;

	public BosObject(BosClass clss) {
		fields = new Map<String,Object>();
		for(String s: clss.getFields())
		{
			fields.put(s, null);
		}
		this.clss = clss;
	}
	
	public BosClass Class()
	{
		return clss;
	}
	
	public String toString()
	{
		return fields.Entries() + " " + clss;
	}
	
	public void putfield(String field, Object o)
	{
		fields.put(field, o);
	}
	
	public Object getField(String field)
	{
		return fields.get(field);
	}

}
